package org.prothliberger.courseCode;

public class GetFreeMemory {
	 
    public static void main(String args[])
    {
            /*
             * get current Java Runtime using getRuntime()
             * method of Runtime class.
             */
            Runtime runtime = Runtime.getRuntime();
           
            /*
             * To determine amount of free memory available to current
             * Java Virtual Machine(JVM), use
             *
             * long freeMemory()
             * method of Runtime class.
             */
             
             long freeMemory = runtime.freeMemory();
             
             System.out.println(freeMemory + " bytes free in JVM");
    }
   
   
}
